<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE topic
  PUBLIC "-//OASIS//DTD DITA Composite//EN" "ditabase.dtd">
<topic id="topic1" xml:lang="en">
  <title id="gs143896">pg_language</title>
  <body>
    <p>The <codeph>pg_language</codeph> system catalog table registers languages in which you can
      write functions or stored procedures. It is populated by <codeph>CREATE LANGUAGE</codeph>.</p>
    <table id="gs143898">
      <title>pg_catalog.pg_language</title>
      <tgroup cols="4">
        <colspec colnum="1" colname="col1" colwidth="131pt"/>
        <colspec colnum="2" colname="col2" colwidth="86pt"/>
        <colspec colnum="3" colname="col3" colwidth="85pt"/>
        <colspec colnum="4" colname="col4" colwidth="147pt"/>
        <thead>
          <row>
            <entry colname="col1">column</entry>
            <entry colname="col2">type</entry>
            <entry colname="col3">references</entry>
            <entry colname="col4">description</entry>
          </row>
        </thead>
        <tbody>
          <row>
            <entry colname="col1"><codeph>lanname</codeph></entry>
            <entry colname="col2">name</entry>
            <entry colname="col3"/>
            <entry colname="col4">Name of the language.</entry>
          </row>
          <row>
            <entry colname="col1"><codeph>lanowner</codeph>
            </entry>
            <entry colname="col2">oid</entry>
            <entry colname="col3">pg_authid.oid</entry>
            <entry colname="col4">Owner of the language.</entry>
          </row>
          <row>
            <entry colname="col1"><codeph>lanispl </codeph></entry>
            <entry colname="col2">boolean</entry>
            <entry colname="col3"/>
            <entry colname="col4">This is false for internal languages (such as SQL) and true for
              user-defined languages. Currently, <codeph>pg_dump</codeph> still uses this to
              determine which languages need to be dumped, but this may be replaced by a different
              mechanism in the future.</entry>
          </row>
          <row>
            <entry colname="col1"><codeph>lanpltrusted </codeph></entry>
            <entry colname="col2">boolean</entry>
            <entry colname="col3"/>
            <entry colname="col4">True if this is a trusted language, which means that it is
              believed not to grant access to anything outside the normal SQL execution environment.
              Only superusers may create functions in untrusted languages.</entry>
          </row>
          <row>
            <entry colname="col1"><codeph>lanplcallfoid</codeph></entry>
            <entry colname="col2">oid</entry>
            <entry colname="col3">pg_proc.oid</entry>
            <entry colname="col4">For noninternal languages this references the language handler,
              which is a special function that is responsible for running all functions that are
              written in the particular language.</entry>
          </row>
          <row>
            <entry colname="col1"><codeph>laninline</codeph></entry>
            <entry colname="col2">oid</entry>
            <entry colname="col3">pg_proc.oid</entry>
            <entry colname="col4">This references a function that is responsible for running
              inline anonymous code blocks (see the <codeph><xref
                  href="../sql_commands/DO.xml#topic1"/></codeph> command). Zero if anonymous blocks
              are not supported.</entry>
          </row>
          <row>
            <entry colname="col1"><codeph>lanvalidator</codeph></entry>
            <entry colname="col2">oid</entry>
            <entry colname="col3">pg_proc.oid</entry>
            <entry colname="col4">This references a language validator function that is responsible
              for checking the syntax and validity of new functions when they are created. Zero if
              no validator is provided.</entry>
          </row>
          <row>
            <entry colname="col1"><codeph>lanacl </codeph></entry>
            <entry colname="col2">aclitem[]</entry>
            <entry colname="col3"/>
            <entry colname="col4">Access privileges for the language.</entry>
          </row>
        </tbody>
      </tgroup>
    </table>
  </body>
</topic>
